(define (my-cons x y)
    (*  
        (expt 2 x)
        (expt 3 y)         
    )
)
(define (my-car z)
    (my-exp z 2)
)
(define (my-cdr z)
    (my-exp z 3)
)

(define (my-exp a b)
    (my-exp-iter a b 0)
)

(define (my-exp-iter a b n )
    (if (= (mod a b) 0)
        (my-exp-iter 
            (/ a b)
            b
            (+ n 1)
        )    
        n        
    )                     
)
(define (mod a b)
    (if (< a b) 
        a
        (mod (- a b) b)
    )
)

(define cons1
    (my-cons 7 8)
)
(display (my-car cons1))
(newline)
(display (my-cdr cons1))
(exit)